﻿using System.Security.Cryptography;

namespace SX.Utils.Tool.Crypto
{
    public class SaltUtil
    {
        public static  byte[] GenerateSalt(int size)
        {
            using (var rng = new RNGCryptoServiceProvider())
            {
                var salt = new byte[size];
                rng.GetBytes(salt);
                return salt;
            }
        }
    }
}
